package com.thrsdk.ui.web;

import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.webkit.JavascriptInterface;
import android.webkit.WebView;


public class JsInterface {
	private  Context mContext;
	private WebView webView;
	
	public JsInterface(Context context) {
		mContext = context;
	}

	public JsInterface(Context context, WebView webView) {
		mContext = context;
	}

	/*
	 * orientation: 1: 横屏 0: 竖屏
	 * */
	@JavascriptInterface
	public  void goBrowser(String url,String type) {
		Intent intent = new Intent("android.intent.action.VIEW", Uri.parse(url));
		mContext.startActivity(intent);
	}
}
